from django.db import models
from django.contrib.auth.models import User
from django.utils import timezone
class Post(models.Model):
    title = models.CharField(max_length=300)
    content = models.TextField()
    author = models.ForeignKey('auth.User', on_delete=models.CASCADE)
    publish_date=models.DateTimeField(default=timezone.now)
    def __str__(self):
        return self.title

# Create your models here.
